package com.dieusoft.box.trade.mapper;

import java.util.List;

import com.dieusoft.box.trade.entity.CostInfo;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

/**
 * @Description: 费用明细信息表
 * @Author: jeecg-boot
 * @Date: 2020-10-22
 * @Version: V1.0
 */
public interface CostInfoMapper extends BaseMapper<CostInfo> {

    public boolean deleteByMainId(@Param("mainId") String mainId);

    public boolean deleteByMainIdAndType(List<String> list);

    public List<CostInfo> selectByMainId(@Param("mainId") String mainId, @Param("type") String type);

    public List<CostInfo> selectByBillNumber(@Param("billNumber") String billNumber);

    public boolean updateByBillNumber(@Param("billNumber") String billNumber,
                                      @Param("updateUser") String updateUser,
                                      @Param("status") String status,
                                      @Param("invoiceNumber") String invoiceNumber);

    public boolean resetByBillNumber(@Param("billNumber") String billNumber,
                                     @Param("updateUser") String updateUser,
                                     @Param("status") String status,
                                     @Param("invoiceNumber") String invoiceNumber);


    List<CostInfo> getCostInfosByIds(List<String> list);
}
